package entities;

import java.io.Serializable;

/**
 *@author Juan Alapin - 324507516
 *@author Giora Yaffe - 036551281
 *@author Shachar Gritzman - 300174026
 *@author Nir Porat - 021515580
*/

public class login implements Serializable {
  
   /**
	 * @author Shachar Gritzman
	 */
	private static final long serialVersionUID = 1L;
	private int userID;
    private String pass1;
    private int permissionLvl;
    
    final public static int ERROR= -1;
    final public static int ALREADY_LOGGED_IN= -2 ;
    final public static int STUDENT=1;
    final public static int PROFESOR=2;
    final public static int ADMINISTRATIVE_STAFF=3;
    final public static int WORKER=4;
    final public static int IS_DEP_MANAGER = 5;

    

   /**
    * Constructor
    */
   public login()
   {
   }
   
   /**
    * Constructor
    * @param id - login ID
    * @param pass - login password
    */
	public login(int id , String pass) { 
		super(); 
		this.userID = id;
		this.pass1= new String (pass);
	}
	
	public int getPermissionLvl()
	{
		return permissionLvl;
		
	}
	
	public void SetPermissionLvl(int Lvl)
	{
		permissionLvl = Lvl;
	}
	
	public int GetUser()
	{
		return userID;
		
	}
	
	public String getPassword()
	{
		return pass1;
		
	}
	
}
